Benjamin Otte [Sat, 31 Dec 2011 14:05:09 +0000 (15:05 +0100)]
styleproperty: Move shorthand declarations to new file
Benjamin Otte [Sat, 31 Dec 2011 13:55:26 +0000 (14:55 +0100)]
styleproperty: border image is not a generic conversion thingy
Benjamin Otte [Sat, 31 Dec 2011 13:34:42 +0000 (14:34 +0100)]
styleproperty: Add a name property
And move the properties array to GtkStylePropertyClass.
Also add some docs.
Benjamin Otte [Sat, 31 Dec 2011 12:50:03 +0000 (13:50 +0100)]
styleproperty: Get rid of _gtk_style_property_is_shorthand()
Use GTK_IS_CSS_SHORTHAND_PROPERTY() instead now that we have it.
Benjamin Otte [Sat, 31 Dec 2011 12:43:31 +0000 (13:43 +0100)]
styleproperty: Split into shorthand and real style properties
Benjamin Otte [Sat, 31 Dec 2011 12:38:22 +0000 (13:38 +0100)]
tests: Quit widget-factory when someone presses quit
Benjamin Otte [Sat, 31 Dec 2011 02:54:17 +0000 (03:54 +0100)]
styleproperty: Make this an object
Benjamin Otte [Sat, 31 Dec 2011 00:14:47 +0000 (01:14 +0100)]
styleproperty: Add _gtk_style_property_query()
This way, we only need to export one function, not 3.
Benjamin Otte [Sat, 31 Dec 2011 00:05:50 +0000 (01:05 +0100)]
styleproperties: Add _gtk_style_properties_peek_property()
Benjamin Otte [Fri, 30 Dec 2011 23:54:51 +0000 (00:54 +0100)]
styleproperties: Remove unused function from private header
_gtk_style_properties_resolve_property() was added erroneously in
c09148ca09081cd009cb9a328441b4b43008e352 but was never implemented.
Benjamin Otte [Fri, 30 Dec 2011 12:14:57 +0000 (13:14 +0100)]
tests: Add a test for 'none'
Benjamin Otte [Fri, 30 Dec 2011 12:13:44 +0000 (13:13 +0100)]
css: 'none' is not a value background-repeat
Benjamin Otte [Fri, 30 Dec 2011 11:51:03 +0000 (12:51 +0100)]
css: Remove generic 'none' handling
Includes updated tests.
Who could have thought that our tests were broken. Ooops.
Benjamin Otte [Fri, 30 Dec 2011 11:53:51 +0000 (12:53 +0100)]
win32: Fix CSS for 'none' value going away
We want colors to be 'transparent' and not 'none'.
Benjamin Otte [Fri, 30 Dec 2011 11:44:16 +0000 (12:44 +0100)]
styleproperty: Add custom 'none' handling
The generic 'none' handling needs to go, because 'none' is not a valid
value most of the time.
Benjamin Otte [Thu, 29 Dec 2011 21:05:10 +0000 (22:05 +0100)]
reftests: Add a test comparing inherit and initial
One test has all properties set to 'inherit', the other to 'initial'.
This should result in the same result, as inherit will ensure every
widget inherits the same value, and for the toplevel 'inherit' is
defined as being identical to 'initial'.
Benjamin Otte [Thu, 29 Dec 2011 21:03:02 +0000 (22:03 +0100)]
reftests: Add a test for a parent in a different state
inherit in those cases should inherit from that different state, not
from this state.
Benjamin Otte [Thu, 29 Dec 2011 15:19:14 +0000 (16:19 +0100)]
tests: Add tests for 'inherit' and 'initial'
Benjamin Otte [Thu, 29 Dec 2011 15:18:12 +0000 (16:18 +0100)]
css: Add generic support for 'inherit' and 'initial'
CSS3 says they work for every property, so here we go.
Benjamin Otte [Thu, 29 Dec 2011 13:26:45 +0000 (14:26 +0100)]
css: Change prototype of _gtk_css_selector_matches()
Passing the length of the widget path that is relevant is not necessary
anymore, it was only useful for inheritance. Instead, we now pass the
state flags and let the selector do the state matching for us.
Benjamin Otte [Thu, 29 Dec 2011 13:20:43 +0000 (14:20 +0100)]
cssprovider: Remove has_inherit flag from rulesets
It's not used anymore
Benjamin Otte [Thu, 29 Dec 2011 13:15:39 +0000 (14:15 +0100)]
cssprovider: Don't do inheritance anymore
Its' done in GtkCssLookup with the help of GtkStyleContext::parent now.
Benjamin Otte [Thu, 29 Dec 2011 13:04:33 +0000 (14:04 +0100)]
css: Make CSS resolving work according to spec
See inline code comments taken from
http://dev.w3.org/csswg/css3-cascade/#cascade
This now respects the special values "inherit" and "initial" properly.
Note that those values cannot be parsed yet. This will be added in a
future commit.
Benjamin Otte [Thu, 29 Dec 2011 13:04:19 +0000 (14:04 +0100)]
styleproperty: Add _gtk_style_property_get_initial_value()
Benjamin Otte [Thu, 29 Dec 2011 12:38:45 +0000 (13:38 +0100)]
css: Pass the parent context to _gtk_css_lookup_resolve()
This way, we can resolve inherit properties.
Benjamin Otte [Thu, 29 Dec 2011 11:40:21 +0000 (12:40 +0100)]
widget: Set parent style context
Benjamin Otte [Thu, 29 Dec 2011 11:30:25 +0000 (12:30 +0100)]
API: Add GtkStyleContext::parent
We need this for proper support of CSS inherit.
Benjamin Otte [Thu, 29 Dec 2011 01:28:32 +0000 (02:28 +0100)]
styleproperty: Pass initial value explicitly
Benjamin Otte [Thu, 29 Dec 2011 01:27:54 +0000 (02:27 +0100)]
css: Add GtkCssSpecialValue
Benjamin Otte [Wed, 28 Dec 2011 23:28:56 +0000 (00:28 +0100)]
css: Add some docs to GtkCssLookup
In particular, document which parts of the CSS value querying we're
doing here.
Benjamin Otte [Wed, 28 Dec 2011 22:16:51 +0000 (23:16 +0100)]
reftests: Add test for pseudo-class matching
Previous GTK matched pseudoclasses not based on CSS rules, but based on
their value in the enumeration. This is now fixed.
Benjamin Otte [Wed, 28 Dec 2011 21:59:55 +0000 (22:59 +0100)]
css: Redo StyleProvider interface
We now use the GtkStleProviderPrivate interface, which hopefully is
faster and more conformant to CSS. Long term, it definitely should be
both.
I would have liked to split this up into multiple commits, but couldn't
find a way.
Benjamin Otte [Wed, 28 Dec 2011 21:05:35 +0000 (22:05 +0100)]
styleproperties: Add a hacky function to redirect color lookups
This will soon be necessary.
FIXME: Make sure this gets removed again.
Benjamin Otte [Wed, 28 Dec 2011 15:15:00 +0000 (16:15 +0100)]
symboliccolor: Add _gtk_symbolic_color_resolve_full()
Benjamin Otte [Tue, 27 Dec 2011 19:41:25 +0000 (20:41 +0100)]
stylecontext: Separate properties by states
We don't want to mix states the wrong way. And the current approach does
that.
Benjamin Otte [Tue, 27 Dec 2011 16:41:48 +0000 (17:41 +0100)]
stylecontext: Pass state to style data lookup function
Benjamin Otte [Fri, 23 Dec 2011 13:30:59 +0000 (14:30 +0100)]
css: Add _gtk_style_property_get_count()
Benjamin Otte [Fri, 23 Dec 2011 13:23:52 +0000 (14:23 +0100)]
cssprovider: Keep a bitmask for the properties
That way we can easily tell wich properties are in use.
Benjamin Otte [Fri, 23 Dec 2011 13:12:04 +0000 (14:12 +0100)]
css: Add _gtk_style_property_get_id()
Benjamin Otte [Fri, 23 Dec 2011 11:31:16 +0000 (12:31 +0100)]
styleproperty: Assign a unique id to every styleproperty
Benjamin Otte [Fri, 23 Dec 2011 21:29:34 +0000 (22:29 +0100)]
tests: Add tests for GtkBitmask
Benjamin Otte [Fri, 23 Dec 2011 11:16:18 +0000 (12:16 +0100)]
gtk: Add GtkBitmask
The CSS code likes to have that very much.
Stefan Sauer [Mon, 9 Jan 2012 17:16:53 +0000 (18:16 +0100)]
gtkscale: fix bogus compare func
The GtkScaleMark values are gdouble, a simple a-b compare func would fail for
values with the same integer value. This breaks the sorting and causes random
marker label placement.
Rob Bradford [Mon, 9 Jan 2012 17:15:00 +0000 (17:15 +0000)]
wayland: Constrain the window configure requests to the window's geometry
When we receive a configure event from Wayland telling us to resize our
surface we check against the geometry constraints for the window to ensure we
do not resize below the minimum and maximum limits.
Rob Bradford [Mon, 9 Jan 2012 17:11:22 +0000 (17:11 +0000)]
wayland: Implement set_geometry_hints vfunc
Our trivial implementation simply saves the passed in parameters into the
Wayland private data structure.
Rui Matos [Thu, 22 Dec 2011 14:49:50 +0000 (14:49 +0000)]
scrolledwindow: Render the background so that it can be styled
Rui Matos [Thu, 22 Dec 2011 14:44:50 +0000 (14:44 +0000)]
window: Stop setting state flags on the style context for drawing
This also removes setting the FOCUSED state flag when
gtk_window_has_toplevel_focus() since this effect can now be done with the new
WINDOW_UNFOCUSED flag instead which actually works better regarding X grabs
and modal windows.
Rui Matos [Thu, 22 Dec 2011 02:59:16 +0000 (02:59 +0000)]
treeview: Use the widget state flags as a base for drawing expanders
Rui Matos [Thu, 22 Dec 2011 02:58:27 +0000 (02:58 +0000)]
treeview: Stop setting state flags on the style context for drawing
Rui Matos [Thu, 22 Dec 2011 00:37:10 +0000 (00:37 +0000)]
trayicon-x11: Stop setting state flags on the style context for drawing
Rui Matos [Thu, 22 Dec 2011 00:31:07 +0000 (00:31 +0000)]
toolitemgroup: Use the widget state flags as a base for drawing
Rui Matos [Thu, 22 Dec 2011 00:12:37 +0000 (00:12 +0000)]
toolbar: Stop setting state flags on the style context for drawing
Rui Matos [Wed, 21 Dec 2011 23:41:50 +0000 (23:41 +0000)]
Revert "button: Stop setting state flags on the style context for drawing"
Setting state flags is actually needed here since this function is called by
GtkButton subclasses which add their specific state flags as a parameter.
This reverts commit
e868b8d6ea04af6e31d7075d09508689873c0df5.
Rui Matos [Wed, 21 Dec 2011 23:27:15 +0000 (23:27 +0000)]
textdisplay: Use the widget state flags as a base for drawing
Rui Matos [Wed, 21 Dec 2011 23:06:39 +0000 (23:06 +0000)]
spinner: Stop setting state flags on the style context for drawing
Rui Matos [Wed, 21 Dec 2011 16:17:18 +0000 (16:17 +0000)]
spinbutton: Use the widget state flags as a base for drawing
Rui Matos [Wed, 21 Dec 2011 15:30:28 +0000 (15:30 +0000)]
separator: Stop setting state flags on the style context for drawing
Rui Matos [Wed, 21 Dec 2011 15:15:10 +0000 (15:15 +0000)]
scale: Stop setting state flags on the style context for drawing
Rui Matos [Wed, 21 Dec 2011 15:01:02 +0000 (15:01 +0000)]
range: Use the widget state flags as a base for drawing
Rui Matos [Wed, 21 Dec 2011 14:20:02 +0000 (14:20 +0000)]
radiobutton: Use the widget state flags as a base for drawing
Rui Matos [Wed, 21 Dec 2011 16:12:17 +0000 (16:12 +0000)]
widget-factory: Make the second spin button insensitive
Rob Bradford [Mon, 9 Jan 2012 16:00:14 +0000 (16:00 +0000)]
wayland: Make the resize and move functions use gdk_device_ungrab
Now that grab and ungrab vfuncs are implemented on GdkDevice then we can use
gdk_device_ungrab to break the implicit grab created by the button press that
triggered the resize and move.
Kristian Høgsberg [Mon, 9 Jan 2012 15:49:57 +0000 (15:49 +0000)]
wayland: Add implementations for the device_grab / device_ungrab vfuncs
This allows the correct implementation of breaking the grab in pointer driven
resize and move.
Signed-off-by: Rob Bradford <rob@linux.intel.com>
Rob Bradford [Mon, 9 Jan 2012 15:07:08 +0000 (15:07 +0000)]
application: Correct the fallback definition for gtk_application_end_session
The function definition used a pointer to the enum value rather than the enum
itself.
This broke the build on platforms that don't have an implmentation of these
functions.
Ryan Lortie [Fri, 6 Jan 2012 18:16:36 +0000 (13:16 -0500)]
GtkButton: do not allow both types of actions
Only allow one of 'action-name' or 'related-action' to be set.
https://bugzilla.gnome.org/show_bug.cgi?id=667394
Ryan Lortie [Fri, 6 Jan 2012 17:51:10 +0000 (12:51 -0500)]
bloatpad: add left/centre/right toolbar buttons
https://bugzilla.gnome.org/show_bug.cgi?id=667394
Ryan Lortie [Fri, 6 Jan 2012 03:22:06 +0000 (22:22 -0500)]
Add new GtkActionable interface
This is the interface for GtkWidgets that can be associated with an
action on a GtkAppicationWindow or associated GtkApplication.
It essentially features 'action-name' and 'action-target' properties
with some associated convenience API.
This interface is implemented by GtkButton and GtkToolButton.
https://bugzilla.gnome.org/show_bug.cgi?id=667394
Ryan Lortie [Mon, 9 Jan 2012 13:29:11 +0000 (14:29 +0100)]
drop debian/ directory
Murray Cumming [Mon, 9 Jan 2012 13:19:21 +0000 (14:19 +0100)]
gtkmain.h: Used GDK_DEPRECATED
If we use just G_GNUC_DEPRECATED then it cannot be disabled by
an ifdef.
Matthias Clasen [Mon, 9 Jan 2012 05:53:53 +0000 (00:53 -0500)]
Revert "GtkWindow: new API to store state in GSettings"
This reverts commit
730765de9163934d9993b25a87f076f1b36ed271.
This needs more thought, committing it on the same day as filing
the bug was premature.
Matthias Clasen [Mon, 9 Jan 2012 05:25:39 +0000 (00:25 -0500)]
Fix up symbol lists
Matthias Clasen [Mon, 9 Jan 2012 03:18:46 +0000 (22:18 -0500)]
Add more tests for GdkRGBA parsing
These examples are taken from bug 667485.
Matthias Clasen [Mon, 9 Jan 2012 03:16:36 +0000 (22:16 -0500)]
Tighten up GdkRGBA parsing
gdk_rgba_parse was accepting too much nonsense, as pointed out
in bug 667485.
Daniel Mustieles [Sun, 8 Jan 2012 19:17:36 +0000 (20:17 +0100)]
Updated Spanish translation
Alexander Shopov [Sun, 8 Jan 2012 15:21:05 +0000 (17:21 +0200)]
Updated Bulgarian translation
Matthias Clasen [Sun, 8 Jan 2012 07:16:26 +0000 (02:16 -0500)]
Fix the gtk_application_end_session implementation
We were passing the wrong flags, causing the meaning of
the request_confirmation parameter to be inverted.
Matthias Clasen [Sun, 8 Jan 2012 07:15:49 +0000 (02:15 -0500)]
Add a test for the new session api
Matthias Clasen [Sun, 8 Jan 2012 02:47:42 +0000 (21:47 -0500)]
Fix doc build
Matthias Clasen [Sun, 8 Jan 2012 02:44:52 +0000 (21:44 -0500)]
Add session management migration chapter
Add some preliminary information about migration from EggSMClient
to GtkApplication.
Matthias Clasen [Sun, 8 Jan 2012 01:44:37 +0000 (20:44 -0500)]
Rearrange migration chapter a bit
The 'checklist' is really just the 'extra credits', so put it
at the end, rather than the beginning.
Matthias Clasen [Sun, 8 Jan 2012 01:01:23 +0000 (20:01 -0500)]
GtkApplication: only allow quit_response when it make sense
This check was present in the OS X implementation, but it
makes sense in the D-Bus implementation as well.
Matthias Clasen [Sun, 8 Jan 2012 00:55:20 +0000 (19:55 -0500)]
Remove some debug spew
Matthias Clasen [Sun, 8 Jan 2012 00:52:14 +0000 (19:52 -0500)]
GtkApplication: Add OS X implementation from EggSMClient
Matthias Clasen [Sun, 8 Jan 2012 00:02:48 +0000 (19:02 -0500)]
Rename rgba test file
Not testing GdkColor here, anymore.
Matthias Clasen [Sun, 8 Jan 2012 00:00:47 +0000 (19:00 -0500)]
Use g_slice_dup
This saves some manual copying.
Pointed out in bug 667473.
Matthias Clasen [Sun, 8 Jan 2012 00:00:32 +0000 (19:00 -0500)]
Add a test for gdk_rgba_copy
Daniel Mustieles [Sat, 7 Jan 2012 17:53:26 +0000 (18:53 +0100)]
Missing file in POTFILEs.in
Paolo Borelli [Sat, 7 Jan 2012 17:05:59 +0000 (18:05 +0100)]
Change param name to make gtk-doc happy.
Benjamin Otte [Sat, 7 Jan 2012 15:14:31 +0000 (16:14 +0100)]
tests: Fix deprecation warnings in prop-editor
Benjamin Otte [Sat, 7 Jan 2012 14:56:26 +0000 (15:56 +0100)]
application: return a value
Martin Pitt [Sat, 7 Jan 2012 09:04:18 +0000 (10:04 +0100)]
gtkapplication.c: Fix syntax error
Previous commit accidentally removed the closing } from
gtk_application_end_session(). Add it back to unbreak the build.
Matthias Clasen [Sat, 7 Jan 2012 05:38:57 +0000 (00:38 -0500)]
Add a trivial implementation of the new apis
For non-X11, this is just a placeholder until we get around
to moving the EggSMClient implementations over.
Matthias Clasen [Sat, 7 Jan 2012 08:15:26 +0000 (03:15 -0500)]
Document the new apis
Matthias Clasen [Sat, 7 Jan 2012 08:04:54 +0000 (03:04 -0500)]
Add gtk_application_end_session
This function allows applications to request that
the user session be ended by logout/shutdown/reboot.
Matthias Clasen [Tue, 3 Jan 2012 20:02:49 +0000 (15:02 -0500)]
GtkApplication: Add an inhibit api
This lets applications block logout and similar actions ahead
of time. Currently only implemented for D-Bus, but Windows has
very similar API since Vista.
Matthias Clasen [Tue, 3 Jan 2012 19:52:29 +0000 (14:52 -0500)]
GtkApplication: Add logout notification
This is fairly basic, allowing applications to learn when
the session manager is about to end the session, and possibly
block this. The only implementation at this point is using the
org.gnome.SessionManager D-Bus interface of gnome-session. It should
be straightforward to port the EggSMClient implementations for
Windows and OS X.
Chun-wei Fan [Sat, 7 Jan 2012 03:21:46 +0000 (11:21 +0800)]
Update Visual C++ property sheets
"Install" (and hence compile with glib-compile-schemas.exe) the new
org.gtk.WindowState.gschema.xml gschema file.
Ryan Lortie [Fri, 6 Jan 2012 20:37:05 +0000 (15:37 -0500)]
GtkWindow: new API to store state in GSettings
https://bugzilla.gnome.org/show_bug.cgi?id=667438
Ryan Lortie [Fri, 6 Jan 2012 15:53:57 +0000 (10:53 -0500)]
GtkBuilder: support parsing GVariant properties
https://bugzilla.gnome.org/show_bug.cgi?id=667394
Piotr Drąg [Fri, 6 Jan 2012 20:18:28 +0000 (21:18 +0100)]
Updated POTFILES.skip